package ynu.sxp.demoapp.repository;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;
import ynu.sxp.demoapp.entity.Orders;

import java.util.List;
import java.util.UUID;

@Repository
public interface OrdersRepository extends JpaRepository<Orders, UUID> {
    List<Orders> findByUserId(String userId);
    Orders findByUserIdAndBusinessIdAndOrderDate(String userId, Integer businessId, String orderDate);
    List<Orders> findByOrderState(Integer status);
}